Package-level declarations

Functions

Link copied to clipboard
inline fun <T> ToolGroup.asInterface(): T

Expose the ToolGroup as an interface

Link copied to clipboard
fun <T> exposeAsInterface(toolCallbackPublisher: ToolCallbackPublisher, intf: Class<T>): T

Expose the given ToolGroup as an interface. This allows code actions to call the tool group as an interface, benefiting from MCP infrastructure without exposing too much power to models. Methods on the relevant interface must match the tool names and the parameters must match the tool parameters. Not all tools need to be supported.